package com.atguigu.cloud.apis;

import com.atguigu.cloud.entities.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "spzx-cloud-user") // 声明当前接口是一个访问user-service的feign的客户端
public interface UserFeignClient {
    @GetMapping(value = "/user/get/{userId}")
    public User findUserByUserId(@PathVariable(value = "userId") Long userId);
}
